package sbc.group1.lab1.mozartspaces;

import org.mozartspaces.core.ContainerReference;

import sbc.group1.lab1.common.CarBody;


class CarBodyProducer extends AbstractProducer {

    public CarBodyProducer(int id, int partsToProduce, Space space, double relativeDefects) {
        super(id, partsToProduce, space, relativeDefects);
    }

    @Override
    protected CarBody createInstance() {
        return new CarBody(this, randomIsDefect());
    }

    @Override
    protected ContainerReference getContainer() {
        return getSpace().getCarBodyContainer();
    }

}
